home *** CD-ROM | disk | FTP | other *** search
Wrap
kkkkmmmmeeeemmmm____aaaalllllllloooocccc((((DDDD3333)))) kkkkmmmmeeeemmmm____aaaalllllllloooocccc((((DDDD3333)))) NNNNAAAAMMMMEEEE _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc - allocate space from kernel free memory SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS _####_iiii_nnnn_cccc_llll_uuuu_dddd_eeee _<<<<_ssss_yyyy_ssss_////_tttt_yyyy_pppp_eeee_ssss_...._hhhh_>>>> _####_iiii_nnnn_cccc_llll_uuuu_dddd_eeee _<<<<_ssss_yyyy_ssss_////_kkkk_mmmm_eeee_mmmm_...._hhhh_>>>> _####_iiii_nnnn_cccc_llll_uuuu_dddd_eeee _<<<<_ssss_yyyy_ssss_////_dddd_dddd_iiii_...._hhhh_>>>> _vvvv_oooo_iiii_dddd _****_kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc_((((_ssss_iiii_zzzz_eeee______tttt _s_i_z_e_,,,, _iiii_nnnn_tttt _f_l_a_g_))))_;;;; AAAArrrrgggguuuummmmeeeennnnttttssss _s_i_z_e Number of bytes to allocate. _f_l_a_g Specifies whether the caller is willing to sleep waiting for memory, etc. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc allocates _s_i_z_e bytes of kernel memory and returns a pointer to the allocated memory. If _f_l_a_g is set to _KKKK_MMMM______SSSS_LLLL_EEEE_EEEE_PPPP, the caller will sleep if necessary until the specified amount of memory is available. If _f_l_a_g is set to _KKKK_MMMM______NNNN_OOOO_SSSS_LLLL_EEEE_EEEE_PPPP, the caller will not sleep, but _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc will return _NNNN_UUUU_LLLL_LLLL if the specified amount of memory is not immediately available. _KKKK_MMMM______PPPP_HHHH_YYYY_SSSS_CCCC_OOOO_NNNN_TTTT_IIII_GGGG: Allocate contiguous physical memory. _CCCC_AAAA_UUUU_TTTT_IIII_OOOO_NNNN_:::: It is best to call _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc with this flag _o_n_l_y at driver initialization time. Otherwise, it may sleep for a very long time. _KKKK_MMMM______CCCC_AAAA_CCCC_HHHH_EEEE_AAAA_LLLL_IIII_GGGG_NNNN_:::: Allocate the requested memory starting at a cache line boundary. This also pads the buffer out to a full cache line. Buffers that the driver will use for _DDDD_MMMM_AAAA must be cache-line aligned and padded to a full cache line. RRRReeeettttuuuurrrrnnnn VVVVaaaalllluuuueeeessss Upon successful completion, _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc returns a pointer to the allocated memory. If _KKKK_MMMM______NNNN_OOOO_SSSS_LLLL_EEEE_EEEE_PPPP is specified and sufficient memory is not immediately available, _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc returns a _NNNN_UUUU_LLLL_LLLL pointer. If _s_i_z_e is set to _0000, _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc returns _NNNN_UUUU_LLLL_LLLL regardless of the value of _f_l_a_g. UUUUSSSSAAAAGGGGEEEE Kernel memory is a limited resource and should be used judiciously. Memory allocated using _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc should be freed as soon as possible. Drivers should not use local freelists for memory or similar schemes that cause the memory to be held for longer than necessary. Since holding memory allocated using _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc for extended periods of time (e.g allocating memory at system startup and never freeing it) can have an adverse effect on overall memory usage and system performance, memory needed for such extended periods should be statically allocated whenever possible. PPPPaaaaggggeeee 1111 kkkkmmmmeeeemmmm____aaaalllllllloooocccc((((DDDD3333)))) kkkkmmmmeeeemmmm____aaaalllllllloooocccc((((DDDD3333)))) The address returned by a successful call to _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc is word-aligned. LLLLeeeevvvveeeellll Base only if _f_l_a_g is set to _KKKK_MMMM______SSSS_LLLL_EEEE_EEEE_PPPP. Initialization, Base or Interrupt if _f_l_a_g is set to _KKKK_MMMM______NNNN_OOOO_SSSS_LLLL_EEEE_EEEE_PPPP. SSSSyyyynnnncccchhhhrrrroooonnnniiiizzzzaaaattttiiiioooonnnn CCCCoooonnnnssssttttrrrraaaaiiiinnnnttttssss May sleep if _f_l_a_g is set to _KKKK_MMMM______SSSS_LLLL_EEEE_EEEE_PPPP. Driver-defined basic locks and read/write locks may be held across calls to this function if _f_l_a_g is _KKKK_MMMM______NNNN_OOOO_SSSS_LLLL_EEEE_EEEE_PPPP, but may not be held if _f_l_a_g is _KKKK_MMMM______SSSS_LLLL_EEEE_EEEE_PPPP. Driver-defined sleep locks may be held across calls to this function regardless of the value of _f_l_a_g. NNNNooootttteeee _kkkk_mmmm_eeee_mmmm______aaaa_llll_llll_oooo_cccc and _kkkk_mmmm_eeee_mmmm______ffff_rrrr_eeee_eeee are intended as replacements for _kkkk_eeee_rrrr_nnnn______mmmm_aaaa_llll_llll_oooo_cccc and _kkkk_eeee_rrrr_nnnn______ffff_rrrr_eeee_eeee. Drivers should use these routines rather than _kkkk_eeee_rrrr_nnnn______mmmm_aaaa_llll_llll_oooo_cccc and _kkkk_eeee_rrrr_nnnn______ffff_rrrr_eeee_eeee. RRRREEEEFFFFEEEERRRREEEENNNNCCCCEEEESSSS _kkkk_mmmm_eeee_mmmm______ffff_rrrr_eeee_eeee(D3), _kkkk_mmmm_eeee_mmmm______zzzz_aaaa_llll_llll_oooo_cccc(D3), Appendix A, Section A.2, "Data cache Write Back and Invalidation" of the _I_R_I_X _D_e_v_i_c_e _D_r_i_v_e_r _P_r_o_g_r_a_m_m_i_n_g _G_u_i_d_e PPPPaaaaggggeeee 2222